package com.example.walletdemo.mapper;

import com.example.walletdemo.entity.Bank;
import com.example.walletdemo.entity.Order;
import com.example.walletdemo.entity.Record;
import com.example.walletdemo.entity.Wallet;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface WalletMapper {
    Wallet selectWalletByUserName(String username);

    int insertOrder(Order order);

    Wallet selectWalletById(int wid);

    int updateWallet(Wallet wallet);

    void insertRecord(Record record);

    Order selectOrdersByOid(int oid);

    boolean updateOrders(Order orders);

    List<Record> selectRecordByWid(int wid);

    Bank selectBankByCardNo(String cardNo);

    Wallet selectWalletBycardNo(String cardNo);

    boolean updateBank(Bank bank);
}
